sources := sever.cc client.cc
objects := sever client

.PHONY:all
all:$(objects)

# 生成可执行
$(objects):$(sources)
	g++ -o sever sever.cc -std=c++11
	g++ -o client client.cc -std=c++11

# 不能这么写
# 1
# $(objects):$(sources)
# 	g++ -o $(objects) $(sources) -std=c++11
# 2
# $(objects):$(sources)
# 	g++ -o $@ $^ -std=c++11

.PHONY:clean
clean:
	rm -f $(objects) fifo